package com.bw.club.model.service

import com.bw.club.model.api.CarApi
import com.bw.club.model.entity.BaseRespEntity
import com.bw.club.model.entity.CarEntity
import okhttp3.OkHttpClient
import okhttp3.logging.HttpLoggingInterceptor
import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory
import javax.inject.Inject

class CarService @Inject constructor() {

    @Inject lateinit var retrofit: Retrofit

    suspend fun fetchCarDatas(): BaseRespEntity<List<CarEntity>> {
        val api = retrofit.create(CarApi::class.java).fetchDatas()
        return api
    }

}